<?php

//UMA new
/** @var \Illuminate\Database\Eloquent\Factory $factory */

use App\Models\CustomerHistory;
use Faker\Generator as Faker;
use App\Models\QueryItem;
use Illuminate\Support\Str;

$factory->define(CustomerHistory::class, function (Faker $faker) {
    return [
        //'bod' => $faker->date(),
        'temporary_member_id' => Str::random(32),
        'input_info' => [
            'sex' => random_int(1, 3),
            //'age' => random_int(1,6),
            'year_of_birth' => random_int(1999, 2002),
            'nation' => random_int(1, 2),
            'marriage' => random_int(1, 2),
            'family_structure' => random_int(1, 5),
            'family_members_quantity' => random_int(1, 5),
            'raise' => random_int(1, 3),
            'driver_lesson_number' => '123412341234',
            'working_school_name' => '東京大学',
            'working_school_name_kana' => 'トウキョウダイガク',
            'working_school_zip' => '123456',
            'working_school_pref' => '東京都',
            'working_school_city' => '渋谷区道玄坂',
            'working_school_town' => '2-10-7',
            'working_school_building' => '新大宗ビル1号館10階',
            'working_school_tel' => '0123456789',
            'hirement' => random_int(1, 5),
            'work_type' => random_int(1, 5),
            'work_responsibility' => random_int(1, 5),
            'work_department' => '売上高',
            'work_place_type' => random_int(1, 5),
            //'working_years' => random_int(1, 2),
            'employment_capital' => random_int(1, 5),
            'employee_quantity' => random_int(1, 5),
            'employment_start_date' => "2018-10",
            'yearly_income' => random_int(100, 2000),
            'salary_type' => random_int(1, 2),
            'insurance' => random_int(1, 3),
            'residence_place' => random_int(1, 5),
            'rent' => 7,
            'balance' => random_int(1, 5),
            'has_borrowing' => random_int(1, 2),
            'auto_loan' => random_int(1, 3),
            'monthly_autoloan_repayment' => 6,
            'cash_loan' => random_int(1, 2),
            'monthly_cashloan_repayment' => 5,
            'other_loan' => random_int(1, 2),
            'monthly_otherloan_repayment' => 5,
            'usage_term_accepted' => 1,
            //'employment_start_date' => random_int(2000, 2019),
        ],
        'usage_term_accepted' => 1,
        // 'score' => random_int(200, 999),
        // 'min_interests' => random_int(10, 20) / 100,
        // 'max_interests' => random_int(20, 30) / 100,
        // 'min_total_payment' => random_int(100000, 500000),
        // 'max_total_payment' => random_int(5000000, 10000000),
        // 'nikkei_score' => random_int(1, 5),
        // 'random_score' => random_int(1, 3),
        //'ip' => '127.0.0.1',
        //'user_agent' => 'Chrome/87.0.4280.141 Safari/537.36',
        //'operation_system' => 'windows',
        'company_id' => 1,
    ];
});
